package com.css.dzj.dzjap.modules.enterprise.entity;

import com.fasterxml.jackson.annotation.JsonFormat;
import org.hibernate.annotations.GenericGenerator;

import javax.persistence.*;

import java.util.Date;
import java.util.Objects;

@Entity
@Table(name = "AP_ENTERPRISE_CREDIT", schema = "DZJAP", catalog = "")
public class ApEnterpriseCreditEntity {
    private String enterpriseCreditId;
    private String enterpriseName;
    private String enterpriseIdNumber;
    private String enterpriseIdType;
    private String enterpriseScore;
    private String enterpriseClassification;
    private Date assessmentDate;
    private String assessmentAuthority;
    private String specause;
    private Date abnormalPutdate;
    private String decorg;
    private String remexcpres;
    private Date remdate;
    private String redecorg;
    private String enterpriseScoreNumber;
    private String createUser;
    private Date createTime;
    private String updateUser;
    private Date updateTime;
    private String delFlag;
    private String enterpriseCredittype;
    private String excpresState;
    private String scoreCause;
    private String creditRes;
    private String enterpriseNotice;
    private String organName;
    // 信用线索原因
    private String creditClueReasons;
    // 涉及负面详情
    private String negativeDetails;
    // 省级
    private String provincial;
    // 市级
    private String municipalLevel;
    // 县级
    private String countyLevel;
    // 国标一级行业名称
    private String nationalStandard1Name;
    // 国标二级行业名称
    private String nationalStandard2Name;
    // 国标三级行业名称
    private String nationalStandard3Name;
    // 国标四级行业名称
    private String nationalStandard4Name;

    @Id
    @Column(name = "ENTERPRISE_CREDIT_ID")
    @GeneratedValue(generator = "SnowflakeId")
    @GenericGenerator(name = "SnowflakeId",strategy = "com.css.dzj.dzjap.common.util.SnowflakeId")
    public String getEnterpriseCreditId() {
        return enterpriseCreditId;
    }

    public void setEnterpriseCreditId(String enterpriseCreditId) {
        this.enterpriseCreditId = enterpriseCreditId;
    }

    @Basic
    @Column(name = "ENTERPRISE_NAME")
    public String getEnterpriseName() {
        return enterpriseName;
    }

    public void setEnterpriseName(String enterpriseName) {
        this.enterpriseName = enterpriseName;
    }

    @Basic
    @Column(name = "ENTERPRISE_ID_NUMBER")
    public String getEnterpriseIdNumber() {
        return enterpriseIdNumber;
    }

    public void setEnterpriseIdNumber(String enterpriseIdNumber) {
        this.enterpriseIdNumber = enterpriseIdNumber;
    }

    @Basic
    @Column(name = "ENTERPRISE_ID_TYPE")
    public String getEnterpriseIdType() {
        return enterpriseIdType;
    }

    public void setEnterpriseIdType(String enterpriseIdType) {
        this.enterpriseIdType = enterpriseIdType;
    }

    @Basic
    @Column(name = "ENTERPRISE_SCORE")
    public String getEnterpriseScore() {
        return enterpriseScore;
    }

    public void setEnterpriseScore(String enterpriseScore) {
        this.enterpriseScore = enterpriseScore;
    }

    @Basic
    @Column(name = "ENTERPRISE_CLASSIFICATION")
    public String getEnterpriseClassification() {
        return enterpriseClassification;
    }

    public void setEnterpriseClassification(String enterpriseClassification) {
        this.enterpriseClassification = enterpriseClassification;
    }

    @Basic
    @Column(name = "ASSESSMENT_DATE")
    @JsonFormat(shape= JsonFormat.Shape.STRING,pattern="yyyy-MM-dd",timezone="GMT+8")
    public Date getAssessmentDate() {
        return assessmentDate;
    }

    public void setAssessmentDate(Date assessmentDate) {
        this.assessmentDate = assessmentDate;
    }

    @Basic
    @Column(name = "ASSESSMENT_AUTHORITY")
    public String getAssessmentAuthority() {
        return assessmentAuthority;
    }

    public void setAssessmentAuthority(String assessmentAuthority) {
        this.assessmentAuthority = assessmentAuthority;
    }

    @Basic
    @Column(name = "SPECAUSE")
    public String getSpecause() {
        return specause;
    }

    public void setSpecause(String specause) {
        this.specause = specause;
    }

    @Basic
    @Column(name = "ABNORMAL_PUTDATE")
    @JsonFormat(shape= JsonFormat.Shape.STRING,pattern="yyyy-MM-dd",timezone="GMT+8")
    public Date getAbnormalPutdate() {
        return abnormalPutdate;
    }

    public void setAbnormalPutdate(Date abnormalPutdate) {
        this.abnormalPutdate = abnormalPutdate;
    }

    @Basic
    @Column(name = "DECORG")
    public String getDecorg() {
        return decorg;
    }

    public void setDecorg(String decorg) {
        this.decorg = decorg;
    }

    @Basic
    @Column(name = "REMEXCPRES")
    public String getRemexcpres() {
        return remexcpres;
    }

    public void setRemexcpres(String remexcpres) {
        this.remexcpres = remexcpres;
    }

    @Basic
    @Column(name = "REMDATE")
    @JsonFormat(shape= JsonFormat.Shape.STRING,pattern="yyyy-MM-dd",timezone="GMT+8")
    public Date getRemdate() {
        return remdate;
    }

    public void setRemdate(Date remdate) {
        this.remdate = remdate;
    }

    @Basic
    @Column(name = "REDECORG")
    public String getRedecorg() {
        return redecorg;
    }

    public void setRedecorg(String redecorg) {
        this.redecorg = redecorg;
    }

    @Basic
    @Column(name = "ENTERPRISE_SCORE_NUMBER")
    public String getEnterpriseScoreNumber() {
        return enterpriseScoreNumber;
    }

    public void setEnterpriseScoreNumber(String enterpriseScoreNumber) {
        this.enterpriseScoreNumber = enterpriseScoreNumber;
    }

    @Basic
    @Column(name = "CREATE_USER")
    public String getCreateUser() {
        return createUser;
    }

    public void setCreateUser(String createUser) {
        this.createUser = createUser;
    }

    @Basic
    @Column(name = "CREATE_TIME")
    @JsonFormat(shape= JsonFormat.Shape.STRING,pattern="yyyy-MM-dd HH:mm",timezone="GMT+8")
    public Date getCreateTime() {
        return createTime;
    }

    public void setCreateTime(Date createTime) {
        this.createTime = createTime;
    }

    @Basic
    @Column(name = "UPDATE_USER")
    public String getUpdateUser() {
        return updateUser;
    }

    public void setUpdateUser(String updateUser) {
        this.updateUser = updateUser;
    }

    @Basic
    @Column(name = "UPDATE_TIME")
    @JsonFormat(shape= JsonFormat.Shape.STRING,pattern="yyyy-MM-dd HH:mm",timezone="GMT+8")
    public Date getUpdateTime() {
        return updateTime;
    }

    public void setUpdateTime(Date updateTime) {
        this.updateTime = updateTime;
    }

    @Basic
    @Column(name = "DEL_FLAG")
    public String getDelFlag() {
        return delFlag;
    }

    public void setDelFlag(String delFlag) {
        this.delFlag = delFlag;
    }

    @Basic
    @Column(name = "ENTERPRISE_CREDITTYPE")
    public String getEnterpriseCredittype() {
        return enterpriseCredittype;
    }

    public void setEnterpriseCredittype(String enterpriseCredittype) {
        this.enterpriseCredittype = enterpriseCredittype;
    }

    @Basic
    @Column(name = "EXCPRES_STATE")
    public String getExcpresState() {
        return excpresState;
    }

    public void setExcpresState(String excpresState) {
        this.excpresState = excpresState;
    }

    @Basic
    @Column(name = "SCORE_CAUSE")
    public String getScoreCause() {
        return scoreCause;
    }

    public void setScoreCause(String scoreCause) {
        this.scoreCause = scoreCause;
    }

    @Basic
    @Column(name = "CREDIT_RES")
    public String getCreditRes() {
        return creditRes;
    }

    public void setCreditRes(String creditRes) {
        this.creditRes = creditRes;
    }

    @Basic
    @Column(name = "ENTERPRISE_NOTICE")
    public String getEnterpriseNotice() {
        return enterpriseNotice;
    }

    public void setEnterpriseNotice(String enterpriseNotice) {
        this.enterpriseNotice = enterpriseNotice;
    }

    @Basic
    @Column(name = "ORGAN_NAME")
    public String getOrganName() {
        return organName;
    }

    public void setOrganName(String organName) {
        this.organName = organName;
    }

    @Basic
    @Column(name = "Credit_clue_reasons")
    public String getCreditClueReasons() {
        return creditClueReasons;
    }

    public void setCreditClueReasons(String creditClueReasons) {
        this.creditClueReasons = creditClueReasons;
    }

    @Basic
    @Column(name = "Negative_Details")
    public String getNegativeDetails() {
        return negativeDetails;
    }

    public void setNegativeDetails(String negativeDetails) {
        this.negativeDetails = negativeDetails;
    }

    @Basic
    @Column(name = "Provincial")
    public String getProvincial() {
        return provincial;
    }

    public void setProvincial(String provincial) {
        this.provincial = provincial;
    }

    @Basic
    @Column(name = "Municipal_Level")
    public String getMunicipalLevel() {
        return municipalLevel;
    }

    public void setMunicipalLevel(String municipalLevel) {
        this.municipalLevel = municipalLevel;
    }

    @Basic
    @Column(name = "County_Level")
    public String getCountyLevel() {
        return countyLevel;
    }

    public void setCountyLevel(String countyLevel) {
        this.countyLevel = countyLevel;
    }

    @Basic
    @Column(name = "National_Standard_1_Name")
    public String getNationalStandard1Name() {
        return nationalStandard1Name;
    }

    public void setNationalStandard1Name(String nationalStandard1Name) {
        this.nationalStandard1Name = nationalStandard1Name;
    }

    @Basic
    @Column(name = "National_Standard_2_Name")
    public String getNationalStandard2Name() {
        return nationalStandard2Name;
    }

    public void setNationalStandard2Name(String nationalStandard2Name) {
        this.nationalStandard2Name = nationalStandard2Name;
    }

    @Basic
    @Column(name = "National_Standard_3_Name")
    public String getNationalStandard3Name() {
        return nationalStandard3Name;
    }

    public void setNationalStandard3Name(String nationalStandard3Name) {
        this.nationalStandard3Name = nationalStandard3Name;
    }

    @Basic
    @Column(name = "National_Standard_4_Name")
    public String getNationalStandard4Name() {
        return nationalStandard4Name;
    }

    public void setNationalStandard4Name(String nationalStandard4Name) {
        this.nationalStandard4Name = nationalStandard4Name;
    }

    @Override
    public boolean equals(Object o) {
        if (this == o) return true;
        if (o == null || getClass() != o.getClass()) return false;
        ApEnterpriseCreditEntity that = (ApEnterpriseCreditEntity) o;
        return Objects.equals(enterpriseCreditId, that.enterpriseCreditId) &&
                Objects.equals(enterpriseName, that.enterpriseName) &&
                Objects.equals(enterpriseIdNumber, that.enterpriseIdNumber) &&
                Objects.equals(enterpriseIdType, that.enterpriseIdType) &&
                Objects.equals(enterpriseScore, that.enterpriseScore) &&
                Objects.equals(enterpriseClassification, that.enterpriseClassification) &&
                Objects.equals(assessmentDate, that.assessmentDate) &&
                Objects.equals(assessmentAuthority, that.assessmentAuthority) &&
                Objects.equals(specause, that.specause) &&
                Objects.equals(abnormalPutdate, that.abnormalPutdate) &&
                Objects.equals(decorg, that.decorg) &&
                Objects.equals(remexcpres, that.remexcpres) &&
                Objects.equals(remdate, that.remdate) &&
                Objects.equals(redecorg, that.redecorg) &&
                Objects.equals(enterpriseScoreNumber, that.enterpriseScoreNumber) &&
                Objects.equals(createUser, that.createUser) &&
                Objects.equals(createTime, that.createTime) &&
                Objects.equals(updateUser, that.updateUser) &&
                Objects.equals(updateTime, that.updateTime) &&
                Objects.equals(delFlag, that.delFlag) &&
                Objects.equals(enterpriseCredittype, that.enterpriseCredittype) &&
                Objects.equals(excpresState, that.excpresState) &&
                Objects.equals(scoreCause, that.scoreCause) &&
                Objects.equals(enterpriseNotice, that.enterpriseNotice) &&
                Objects.equals(organName, that.organName) &&
                Objects.equals(creditClueReasons, that.creditClueReasons) &&
                Objects.equals(negativeDetails, that.negativeDetails) &&
                Objects.equals(provincial, that.provincial) &&
                Objects.equals(municipalLevel, that.municipalLevel) &&
                Objects.equals(countyLevel, that.countyLevel) &&
                Objects.equals(nationalStandard1Name, that.nationalStandard1Name) &&
                Objects.equals(nationalStandard2Name, that.nationalStandard2Name) &&
                Objects.equals(nationalStandard3Name, that.nationalStandard3Name) &&
                Objects.equals(nationalStandard4Name, that.nationalStandard4Name) &&
                Objects.equals(creditRes, that.creditRes);
    }

    @Override
    public int hashCode() {
        return Objects.hash(enterpriseCreditId, enterpriseName, enterpriseIdNumber, enterpriseIdType, enterpriseScore, enterpriseClassification, assessmentDate, assessmentAuthority, specause, abnormalPutdate, decorg, remexcpres, remdate, redecorg, enterpriseScoreNumber, createUser, createTime, updateUser, updateTime, delFlag, enterpriseCredittype, excpresState, scoreCause, creditRes, enterpriseNotice, organName,creditClueReasons, negativeDetails, provincial, municipalLevel, countyLevel, nationalStandard1Name, nationalStandard2Name, nationalStandard3Name, nationalStandard4Name);
    }
}
